package tt.com.mourninghallmanager.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import tt.com.common.model.Dead;
import tt.com.common.model.DeadHall;
import tt.com.common.model.Hall;

import java.util.List;

public interface IDeadHallMapper extends BaseMapper<DeadHall> {
    //分页查询所有空闲灵堂
    List<Hall> changeFreeDeadHall(@Param(value = "pageIndex") int pageIndex,@Param(value = "pageSize") int pageSize);
    //查询空闲灵堂数量
    List<Hall> selectFreeDeadHallNum();
    //修改灵堂的启用状态(修改为已启用)
    int updateHallStatus(@Param(value = "hallId") String hallId);
    //修改灵堂的启用状态(修改为未启用)
    int updateHallStatusNo(@Param(value = "hallId") String hallId);
    //逝者信息预登记
    int addHeadHumanMeassage(@Param(value = "dead") Dead dead);
    //查询信息
    List<DeadHall> selectDeadHallMessage(@Param(value = "deadHall") DeadHall deadHall,@Param(value = "pageIndex") int pageIndex,@Param(value = "pageSize") int pageSize);
    //将灵堂设置为启用
    int updateDeadHallStatusBy0(@Param(value = "id") String id);
    //将灵堂设置为未启用
    int updateDeadHallStatusBy1(@Param(value = "id") String id);
}
